RequestMsgBoxArgs.cs
Language: C#
Last Modified: 2020-06-27 1:58:36 PM UTC
File Size: 1498 bytes
Last Modified: 2020-06-27 1:58:36 PM UTC
File Size: 1498 bytes
http://www.penguinstew.ca/example/MVVMbase/ViewModelBase/RequestMsgBoxArgs.cs
using System;
using System.Windows;
namespace Penguin.MVVMBase.ViewModelBase
{
/// <summary>
/// EventArgs for RequestMsgBox event
/// </summary>
public class RequestMsgBoxArgs : EventArgs
{
/// <summary>
/// The text to display in the MessageBox
/// </summary>
public string MessageBoxText { get; set; }
/// <summary>
/// The caption to display in the MessageBox
/// </summary>
public string MessageBoxCaption { get; set; }
/// <summary>
/// The buttons to display in the MessageBox
/// </summary>
public MessageBoxButton MessageBoxButtons { get; set; }
/// <summary>
/// The image to display in the MessageBox
/// </summary>
public MessageBoxImage MessageBoxIcon { get; set; }
/// <summary>
/// The action to call with the MessageBox result
/// </summary>
public Action<MessageBoxResult> Callback { get; set; }
public RequestMsgBoxArgs(string messageBoxText, string messageBoxCaption, MessageBoxButton messageBoxButtons,
MessageBoxImage messageBoxIcon, Action<MessageBoxResult> callback)
{
MessageBoxText = messageBoxText;
MessageBoxCaption = messageBoxCaption;
MessageBoxButtons = messageBoxButtons;
MessageBoxIcon = messageBoxIcon;
Callback = callback;
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46